package com.jzy.bxb.manage.service;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import com.jzy.bxb.manage.core.service.MongoBaseService;
import com.jzy.bxb.model.mongo.dao.SuggestDao;
import com.jzy.bxb.model.mongo.entity.Suggest;

/**
 * 建议，反馈
 * @author JiangZhiYong
 * QQ:359135103
 */
@Service
public class SuggestService extends MongoBaseService<Suggest, String>{

	@Autowired
	private SuggestDao suggestDao;

	public SuggestDao getSuggestDao() {
		return suggestDao;
	}

	public void setSuggestDao(SuggestDao suggestDao) {
		this.suggestDao = suggestDao;
		setBaseDao(suggestDao);
	}
	
	/**
	 * 全部建议
	 * @return
	 */
	public List<Suggest> getSuggests(){
		return suggestDao.createQuery().asList();
	}
}
